$OpenBSD: patch-CMakeLists_txt,v 1.1.1.1 2016/12/02 14:57:41 sthen Exp $
--- CMakeLists.txt.orig	Thu Jul  7 09:06:40 2016
+++ CMakeLists.txt	Thu Jul  7 09:19:03 2016
@@ -168,10 +168,14 @@ ENDMACRO(ProcessPackage name)
 
 ############################# OS SECTION #############################################
 SET(TAR "tar")
-IF(CMAKE_SYSTEM_NAME MATCHES "^.*BSD$|DragonFly")
+IF(CMAKE_SYSTEM_NAME MATCHES "FreeBSD|DragonFly")
 	SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D_BSD_SOURCE -DFREEBSD")
 	SET(TAR "gtar")
 	MESSAGE(STATUS "Configuring for FreeBSD")
+ELSEIF(CMAKE_SYSTEM_NAME MATCHES ".*BSD")
+	SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D_BSD_SOURCE")
+	SET(TAR "gtar")
+	MESSAGE(STATUS "Configuring for other BSD")
 ENDIF()
 IF(CMAKE_SYSTEM_NAME STREQUAL "Darwin")
 	SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D_BSD_SOURCE -DDARWIN")
